Crate three_d_asset

source ·
Expand description

A set of common assets that are useful when doing graphics, for example TriMesh, Texture2D or PbrMaterial. These assets can be loaded using the io module or constructed manually. When in memory, the assets can be for example be

  • visualised, for example using the three-d crate or in a CPU ray tracer
  • imported into a rust-based game engine
  • edited and saved again

Re-exports§

Modules§

  • Contain geometry asset definitions.
  • Contains functionality to load any type of asset runtime as well as parsers for common 3D assets. Also includes functionality to save data which is limited to native.
  • Contain material asset definitions.
  • Contain the basic types used by the 3D specific data types. Mostly basic math functionality which is an re-export of cgmath.
  • Contain texture asset definitions.
  • Contain volume asset definitions.

Structs§

  • Represents a camera used for viewing 3D assets.
  • A set of key frames and transformations associated with a specific animation for a specific Primitive.
  • Contains a set of key frames for rotations, translations, scales and morph weights.
  • A Model contain the same data as a Scene, it’s just stored in flat arrays instead of in a tree structure. You can convert from a Scene to a Model, but not the other way, because the tree structure is lost in the conversion.
  • A node in a Scene graph. Each node may contain a set of children nodes, hence the whole Scene representaion has a tree structure.
  • A pixel coordinate in physical pixels, where x is on the horizontal axis with zero being at the left edge and y is on the vertical axis with zero being at bottom edge.
  • A part of a Model containing exactly one Geometry, an optional reference to a material and information necessary to calculate the transformation that should be applied to the geometry.
  • Representation of a set of objects as a scene graph. Specifically, a Scene contains a tree of Nodes, where the nodes contain the Geometry data. A Scene can easily be converted into a Model, if it is more desirable with a flat arrays instead of a tree structure.
  • UV coordinates which must be between (0, 0) indicating the bottom left corner and (1, 1) indicating the top right corner.
  • Defines the part of the screen/render target that the camera is projecting into. All values should be in physical pixels.

Enums§

  • Error from this crate.
  • The type of projection used by a camera (orthographic or perspective) including parameters.

Type Aliases§

  • A result for this crate.